package com.zhy.springcloud.enetities;

import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

/**
 * @Author zhy
 * @Description json封装实体类
 * @ClassName CommonResult
 * @Date 2020/11/12 18:32
 **/
@Data
@AllArgsConstructor //全参
@NoArgsConstructor //空参
public class CommonResult<T> {

    private Integer code;
    private String message;
    private T data;

    public CommonResult(Integer code, String message){
        this(code,message,null);
    }

}
